-
Notifications
You must be signed in to change notification settings - Fork 33
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement PNI #285
Implement PNI #285
Conversation
@gferon: in the linking fix #271, you set some Kyber last resort keys:
The problem is that the storage does not realize this is a last resort key, and we should probably make sure to tag it as such. Second, this pre key generation code is duplicate with AccountManager, we might want to clean that up. |
I remember adding a comment about this but didn't see some bad side effects 😅 and decided to go forward with the fix since everything was broken. Thanks for that! |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #285 +/- ##
==========================================
- Coverage 17.12% 3.34% -13.78%
==========================================
Files 38 37 -1
Lines 3078 2898 -180
==========================================
- Hits 527 97 -430
- Misses 2551 2801 +250 ☔ View full report in Codecov by Sentry. |
Good for a first look. We'll test it thoroughly (as thoroughly as this complex thing can get tested...) with Whisperfish before getting this in. |
local_aci: ServiceAddress, | ||
local_pni: ServiceAddress, | ||
aci_identity: IdentityKeyPair, | ||
pni_identity: Option<IdentityKeyPair>, | ||
device_id: DeviceId, | ||
) -> Self { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since messages are always sent using the account identity[citation needed], we could instead pass the Aci and Pni stores separately into the MessageSender, and instantiate the ServiceCipher
internally? That could reduce the number of arguments, because we won't have to pass the aci_identity
, pni_identity
nor the cipher
anymore.
Imagine. This works. |
Amazing, I'll integrate and test it in presage today! |
Quite a bit of work on the caller side, as usual, you can check out WF: |
I've been using this with Whisperfish for a day or two now, and there haven't been anything weird to report about (after the initial shenanigans)! |
Just started the integration with presage, may I push small adjustment commits directly on this branch? |
I guess so, further fixes are always welcome. I'd still prefer the trial-and-error part happening in a fork or local check-out. Having said that, me and Ruben did exactly that a few days back 😅 Some final cleanup may take place regardless. |
As long as you don't squash anything, I think that'd be fine. |
Go for it, I have a bunch of changes that I'll try to commit in separate changes, since they are mostly quality of life improvements and I went a little bit extra with my changes 😂 |
Fix #206, continuation of #275
TODO:
NewDeviceRegistration
to useIdentityKey
instead ofPublicKey
or even straightIdentityKeyPair
. Strong types ftw.Maybe TODO: